package goods.api;

import goods.model.ProductStandard;
import org.springframework.data.domain.Page;
import org.springframework.data.domain.Pageable;

import java.util.List;

/**
 * Created by ChenGeng on 2016/11/7.
 */
public interface ProductStandardApi {

    public Page<ProductStandard> findProductStandardByName(String name, Pageable pageable);

    /**
     * 根据规格id编号删除规格
     */
    public void deleteDataById(String id);

    /**
     * 根据规格id编号找规格
     * @return
     */
    public ProductStandard findProductStandById(String id);

    /**
     * 查询所有商品规格
     * @return
     */
    public List<ProductStandard> findAllStandard();

    /**
     * 保存规格
     */
    public ProductStandard saveProductStandard(ProductStandard productStandard);

    public String toString();

    public ProductStandard findStandardByIndex(int index);

}
